package com.wangku.springmvc.controller;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.wangku.springmvc.common.BaseController;
import com.wangku.springmvc.entity.PageData;
import com.wangku.springmvc.utils.AppResponse;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @description: 小程序用户信息
 * @author: 李赛赛
 * @create: 2018-08-17 11:56
 **/
@Controller
@RequestMapping(value = "wxUserInfo")
public class WxUserInfoController extends BaseController {

    /**
     * @param
     * @return
     * @description 获取用户信息
     * @date 2018/8/17 11:58
     */
    @RequestMapping(value = "/getUserInfo")
    @ResponseBody
    public AppResponse getUserInfo2() {
        JSONObject data = new JSONObject();
        PageData userInfo = getWxUserInfo();
        data.put("userInfo", userInfo);
        return AppResponse.success(data);
    }

}
